package cn.caidabao.camunda_demo.controller;

import cn.caidabao.camunda_demo.service.ITCaiProcessService;
import com.alibaba.fastjson2.JSON;
import com.alibaba.fastjson2.JSONObject;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author cjn
 * @since 2024-07-17 11:54
 */
@RestController
@RequestMapping("/api/caiProcess")
@AllArgsConstructor
public class CaiProcessController {

    private final ITCaiProcessService caiProcessService;

    @GetMapping("/list")
    public List<JSONObject> list(){
        return caiProcessService.jsonList();
    }
}
